//*********************************************************
//
//    Copyright (c) Microsoft. All rights reserved.
//    This code is licensed under the Apache License, Version 2.0.
//    THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF
//    ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY
//    IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR
//    PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.
//
//*********************************************************

using System;
using System.Collections.Generic;
using System.Text;
using Microsoft.Research.DataLayer;

namespace ConnectionManagerEditor
{
    public class BasicConnectionManager : ConnectionManagerBase
    {
        private BasicConnectionManager(CancelBehavior cancelBehavior, string storeFile)
            : base(cancelBehavior, storeFile)
        {
        }

        private BasicConnectionManager(CancelBehavior cancelBehavior, ConfigScope scope)
            : base(cancelBehavior, scope)
        {
        }

        public static BasicConnectionManager Create(CancelBehavior cancelBehavior, string storeFile)
        {
            return new BasicConnectionManager(cancelBehavior, storeFile);
        }

        public static BasicConnectionManager Create(CancelBehavior cancelBehavior, ConfigScope scope)
        {
            return new BasicConnectionManager(cancelBehavior, scope);
        }

        protected override string ConfigFile
        {
            get { return alternateStorage; }
        }

        protected override string DefaultConfigFile
        {
            get { return alternateStorage; }
        }

        protected override string ConfigFileName
        {
            get { return alternateStorage; }
        }

        protected override ConnectionManagerBase CreateNewInstance(CancelBehavior cancelBehavior, ConfigScope scope)
        {
            return BasicConnectionManager.Create(cancelBehavior, scope);
        }
    }
}
